<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.10"/>
<title>HE_Mesh2014: wblut.math.WB_Math Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">HE_Mesh2014
   &#160;<span id="projectnumber">2.0.11</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.10 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="namespaces.html"><span>Packages</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="namespacewblut.html">wblut</a></li><li class="navelem"><a class="el" href="namespacewblut_1_1math.html">math</a></li><li class="navelem"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html">WB_Math</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="classwblut_1_1math_1_1_w_b___math-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">wblut.math.WB_Math Class Reference</div>  </div>
</div><!--header-->
<div class="contents">
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:a8ff813b04c502ab89be561862b0ee2dd"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a8ff813b04c502ab89be561862b0ee2dd">fastAbs</a> (final double x)</td></tr>
<tr class="separator:a8ff813b04c502ab89be561862b0ee2dd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa49f2dcb84ec960cb0b8b068ca6a6106"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#aa49f2dcb84ec960cb0b8b068ca6a6106">max</a> (final double x, final double y)</td></tr>
<tr class="separator:aa49f2dcb84ec960cb0b8b068ca6a6106"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a147b41aec6764fddc8cfe90bb5a082c8"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a147b41aec6764fddc8cfe90bb5a082c8">min</a> (final double x, final double y)</td></tr>
<tr class="separator:a147b41aec6764fddc8cfe90bb5a082c8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a17d1a17a0e6b74ecc50feaa5dde05bdc"><td class="memItemLeft" align="right" valign="top">static int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a17d1a17a0e6b74ecc50feaa5dde05bdc">max</a> (final int x, final int y)</td></tr>
<tr class="separator:a17d1a17a0e6b74ecc50feaa5dde05bdc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3916a923fb43289556d07e1c7c210001"><td class="memItemLeft" align="right" valign="top">static int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a3916a923fb43289556d07e1c7c210001">min</a> (final int x, final int y)</td></tr>
<tr class="separator:a3916a923fb43289556d07e1c7c210001"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac4aa340036b0cc2564b1258f1081aa8e"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#ac4aa340036b0cc2564b1258f1081aa8e">max</a> (final double x, final double y, final double z)</td></tr>
<tr class="separator:ac4aa340036b0cc2564b1258f1081aa8e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae19b263c9ad1a38ade1811debb1d2da3"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#ae19b263c9ad1a38ade1811debb1d2da3">min</a> (final double x, final double y, final double z)</td></tr>
<tr class="separator:ae19b263c9ad1a38ade1811debb1d2da3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5a8664a0ff2fa076645a46317bfb3c12"><td class="memItemLeft" align="right" valign="top">static final int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a5a8664a0ff2fa076645a46317bfb3c12">floor</a> (final float x)</td></tr>
<tr class="separator:a5a8664a0ff2fa076645a46317bfb3c12"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a838ec81d05df80c76ad725a002946805"><td class="memItemLeft" align="right" valign="top">static final float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a838ec81d05df80c76ad725a002946805">fastLog2</a> (final float i)</td></tr>
<tr class="separator:a838ec81d05df80c76ad725a002946805"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a785b4d37e6584b63c38bcab1737270b8"><td class="memItemLeft" align="right" valign="top">static final float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a785b4d37e6584b63c38bcab1737270b8">fastPow2</a> (final float i)</td></tr>
<tr class="separator:a785b4d37e6584b63c38bcab1737270b8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a54bfe116c82fe28d2d10246d3fa97f5b"><td class="memItemLeft" align="right" valign="top">static final float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a54bfe116c82fe28d2d10246d3fa97f5b">fastPow</a> (final float a, final float b)</td></tr>
<tr class="separator:a54bfe116c82fe28d2d10246d3fa97f5b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aedfdd3b2549886d9e25e4038b53fdf3f"><td class="memItemLeft" align="right" valign="top">static final float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#aedfdd3b2549886d9e25e4038b53fdf3f">fastInvSqrt</a> (float x)</td></tr>
<tr class="separator:aedfdd3b2549886d9e25e4038b53fdf3f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad3b055deec4a3d9d3c78aad4c011380a"><td class="memItemLeft" align="right" valign="top">static final float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#ad3b055deec4a3d9d3c78aad4c011380a">fastSqrt</a> (final float x)</td></tr>
<tr class="separator:ad3b055deec4a3d9d3c78aad4c011380a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4f6ba7a1d1293ebdaaa93ef99d8a4c08"><td class="memItemLeft" align="right" valign="top">static int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a4f6ba7a1d1293ebdaaa93ef99d8a4c08">getExp</a> (final double v)</td></tr>
<tr class="separator:a4f6ba7a1d1293ebdaaa93ef99d8a4c08"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a348979ce2b880d97aeb019c295b4c183"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a348979ce2b880d97aeb019c295b4c183">hypot</a> (final double a, final double b)</td></tr>
<tr class="separator:a348979ce2b880d97aeb019c295b4c183"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a162ac4b9963922fdb896bd04ac49b679"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a162ac4b9963922fdb896bd04ac49b679">logBase2</a> (final double value)</td></tr>
<tr class="separator:a162ac4b9963922fdb896bd04ac49b679"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab8c95b050faded43cbd0810dbb71c138"><td class="memItemLeft" align="right" valign="top">static boolean&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#ab8c95b050faded43cbd0810dbb71c138">isPowerOfTwo</a> (final int value)</td></tr>
<tr class="separator:ab8c95b050faded43cbd0810dbb71c138"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af18b867bce481671dec8429e66e5be7a"><td class="memItemLeft" align="right" valign="top">static int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#af18b867bce481671dec8429e66e5be7a">powerOfTwoCeiling</a> (final int reference)</td></tr>
<tr class="separator:af18b867bce481671dec8429e66e5be7a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a43d6a6bff6f770f30fd74eab80065f63"><td class="memItemLeft" align="right" valign="top">static int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a43d6a6bff6f770f30fd74eab80065f63">powerOfTwoFloor</a> (final int reference)</td></tr>
<tr class="separator:a43d6a6bff6f770f30fd74eab80065f63"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aeae4e3cba9620b694564e83c411221d8"><td class="memItemLeft" align="right" valign="top">static double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#aeae4e3cba9620b694564e83c411221d8">clamp</a> (final double v, final double <a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a147b41aec6764fddc8cfe90bb5a082c8">min</a>, final double <a class="el" href="classwblut_1_1math_1_1_w_b___math.html#aa49f2dcb84ec960cb0b8b068ca6a6106">max</a>)</td></tr>
<tr class="separator:aeae4e3cba9620b694564e83c411221d8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a505574dbb4c3ec5f74adb74b4c3fdcd0"><td class="memItemLeft" align="right" valign="top">static int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a505574dbb4c3ec5f74adb74b4c3fdcd0">clamp</a> (final int v, final int <a class="el" href="classwblut_1_1math_1_1_w_b___math.html#a147b41aec6764fddc8cfe90bb5a082c8">min</a>, final int <a class="el" href="classwblut_1_1math_1_1_w_b___math.html#aa49f2dcb84ec960cb0b8b068ca6a6106">max</a>)</td></tr>
<tr class="separator:a505574dbb4c3ec5f74adb74b4c3fdcd0"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>A collection of fast and approximated math functions. Not as robust as the JAVA implementations when dealing with special values (NaN etc). Some functions only give an approximation.</p>
<dl class="section author"><dt>Author</dt><dd>Frederik Vanhoutte, W:Blut </dd></dl>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="aeae4e3cba9620b694564e83c411221d8"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.clamp </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>v</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>min</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>max</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Clamps a value to a given range.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">v</td><td>the value to clamp. </td></tr>
    <tr><td class="paramname">min</td><td>the floor. </td></tr>
    <tr><td class="paramname">max</td><td>the ceiling</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the nearest value such that min &lt;= v &lt;= max. </dd></dl>

</div>
</div>
<a class="anchor" id="a505574dbb4c3ec5f74adb74b4c3fdcd0"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static int wblut.math.WB_Math.clamp </td>
          <td>(</td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>v</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>min</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>max</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Clamps an integer value to a given range.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">v</td><td>the value to clamp. </td></tr>
    <tr><td class="paramname">min</td><td>the floor. </td></tr>
    <tr><td class="paramname">max</td><td>the ceiling</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the nearest value such that min &lt;= v &lt;= max. </dd></dl>

</div>
</div>
<a class="anchor" id="a8ff813b04c502ab89be561862b0ee2dd"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.fastAbs </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>x</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast absolute value.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>abs(x) </dd></dl>

</div>
</div>
<a class="anchor" id="aedfdd3b2549886d9e25e4038b53fdf3f"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static final float wblut.math.WB_Math.fastInvSqrt </td>
          <td>(</td>
          <td class="paramtype">float&#160;</td>
          <td class="paramname"><em>x</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast inverse sqrt approximation for floats.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>result </dd></dl>

</div>
</div>
<a class="anchor" id="a838ec81d05df80c76ad725a002946805"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static final float wblut.math.WB_Math.fastLog2 </td>
          <td>(</td>
          <td class="paramtype">final float&#160;</td>
          <td class="paramname"><em>i</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast log2 approximation for floats.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">i</td><td>the i </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>result </dd></dl>

</div>
</div>
<a class="anchor" id="a54bfe116c82fe28d2d10246d3fa97f5b"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static final float wblut.math.WB_Math.fastPow </td>
          <td>(</td>
          <td class="paramtype">final float&#160;</td>
          <td class="paramname"><em>a</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final float&#160;</td>
          <td class="paramname"><em>b</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast power approximation for floats.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">a</td><td>the a </td></tr>
    <tr><td class="paramname">b</td><td>exponent </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>result </dd></dl>

</div>
</div>
<a class="anchor" id="a785b4d37e6584b63c38bcab1737270b8"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static final float wblut.math.WB_Math.fastPow2 </td>
          <td>(</td>
          <td class="paramtype">final float&#160;</td>
          <td class="paramname"><em>i</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast square power approximation for floats.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">i</td><td>the i </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>result </dd></dl>

</div>
</div>
<a class="anchor" id="ad3b055deec4a3d9d3c78aad4c011380a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static final float wblut.math.WB_Math.fastSqrt </td>
          <td>(</td>
          <td class="paramtype">final float&#160;</td>
          <td class="paramname"><em>x</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast sqrt approximation for floats.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>result </dd></dl>

</div>
</div>
<a class="anchor" id="a5a8664a0ff2fa076645a46317bfb3c12"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static final int wblut.math.WB_Math.floor </td>
          <td>(</td>
          <td class="paramtype">final float&#160;</td>
          <td class="paramname"><em>x</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Largest integer smaller than value.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>result </dd></dl>

</div>
</div>
<a class="anchor" id="a4f6ba7a1d1293ebdaaa93ef99d8a4c08"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static int wblut.math.WB_Math.getExp </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>v</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">v</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd></dd></dl>

</div>
</div>
<a class="anchor" id="a348979ce2b880d97aeb019c295b4c183"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.hypot </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>a</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>b</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>sqrt(a^2 + b^2) without under/overflow. *</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">a</td><td></td></tr>
    <tr><td class="paramname">b</td><td></td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd></dd></dl>

</div>
</div>
<a class="anchor" id="ab8c95b050faded43cbd0810dbb71c138"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static boolean wblut.math.WB_Math.isPowerOfTwo </td>
          <td>(</td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>value</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Convenience method for testing whether a value is a power of two.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">value</td><td>the value to test for power of 2</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>true if power of 2, else false </dd></dl>

</div>
</div>
<a class="anchor" id="a162ac4b9963922fdb896bd04ac49b679"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.logBase2 </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>value</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Convenience method to compute the log base 2 of a value.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">value</td><td>the value to take the log of.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the log base 2 of the specified value. </dd></dl>

</div>
</div>
<a class="anchor" id="aa49f2dcb84ec960cb0b8b068ca6a6106"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.max </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>y</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast max.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
    <tr><td class="paramname">y</td><td>the y </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>max(x,y) </dd></dl>

</div>
</div>
<a class="anchor" id="a17d1a17a0e6b74ecc50feaa5dde05bdc"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static int wblut.math.WB_Math.max </td>
          <td>(</td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>y</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast max.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
    <tr><td class="paramname">y</td><td>the y </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>max(x,y) </dd></dl>

</div>
</div>
<a class="anchor" id="ac4aa340036b0cc2564b1258f1081aa8e"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.max </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>y</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>z</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Maximum of three values.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
    <tr><td class="paramname">y</td><td>the y </td></tr>
    <tr><td class="paramname">z</td><td>the z </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>max(x,y,z) </dd></dl>

</div>
</div>
<a class="anchor" id="a147b41aec6764fddc8cfe90bb5a082c8"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.min </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>y</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast min.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
    <tr><td class="paramname">y</td><td>the y </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>min(x,y) </dd></dl>

</div>
</div>
<a class="anchor" id="a3916a923fb43289556d07e1c7c210001"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static int wblut.math.WB_Math.min </td>
          <td>(</td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>y</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Fast min.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
    <tr><td class="paramname">y</td><td>the y </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>min(x,y) </dd></dl>

</div>
</div>
<a class="anchor" id="ae19b263c9ad1a38ade1811debb1d2da3"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static double wblut.math.WB_Math.min </td>
          <td>(</td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>y</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">final double&#160;</td>
          <td class="paramname"><em>z</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Minimum of three values.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>the x </td></tr>
    <tr><td class="paramname">y</td><td>the y </td></tr>
    <tr><td class="paramname">z</td><td>the z </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>min(x,y,z) </dd></dl>

</div>
</div>
<a class="anchor" id="af18b867bce481671dec8429e66e5be7a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static int wblut.math.WB_Math.powerOfTwoCeiling </td>
          <td>(</td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>reference</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the value that is the nearest power of 2 greater than or equal to the given value.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">reference</td><td>the reference value. The power of 2 returned is greater than or equal to this value.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the value that is the nearest power of 2 greater than or equal to the reference value </dd></dl>

</div>
</div>
<a class="anchor" id="a43d6a6bff6f770f30fd74eab80065f63"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static int wblut.math.WB_Math.powerOfTwoFloor </td>
          <td>(</td>
          <td class="paramtype">final int&#160;</td>
          <td class="paramname"><em>reference</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Returns the value that is the nearest power of 2 less than or equal to the given value.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">reference</td><td>the reference value. The power of 2 returned is less than or equal to this value.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the value that is the nearest power of 2 less than or equal to the reference value </dd></dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>src/wblut/math/<a class="el" href="_w_b___math_8java.html">WB_Math.java</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Wed Jun 1 2016 00:03:05 for HE_Mesh2014 by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.10
</small></address>
</body>
</html>
